package demo;

/**
 * @Author 12629
 * @Description：
 */
public class Test {

    public static void func(int a) throws MyException{
        if(a == 10) {
            throw new MyException("哈哈！");
        }
    }

    public static void main(String[] args) {
        try {
            func(10);
        }catch (MyException myException) {
            myException.printStackTrace();
        }finally {
            System.out.println("fdsafsafa");
        }
    }
}
